<%@ include file="/common/taglibs.jsp"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<head>
	<meta http-equiv="Cache-Control" content="no-store" />
	<meta http-equiv="Pragma" content="no-cache" />
	<title><fmt:message key="feedback.reply.title" /></title>
	<content tag="heading">
	<fmt:message key="feedback.reply.title" />
	</content>
	<style>
	   .replayContent{
	     background: #F7F8F9;
	   }
	   
	   .over{ background:#F7F8F9; }
	   .color1{
	     color:#1E50A2;
	     font-weight: bold;
	   }
	   .color2{
	     color:#1E50A2;
	   }
	</style>
</head>
<body>

		 <div class="title">
			<fmt:message key="feedback.reply.title" />
		</div>
		<div class="titleCenter">
			<h3><fmt:message key="feedback.reply.mainSubject" />${fn:length(replyList)}</h3>
			<table id="replayLists" class="memberCenter" width="100%" border="0" cellspacing="0" cellpadding="0">
			<tr>
			  <td>
			   <table width="100%"  border="0" cellspacing="0" cellpadding="0" style="border-bottom:1px dotted #AFAFB0 ">
				<tr>
					<td width="72%" align="left">
					  <span class="color1"> <c:out value="${feedback.appUser.username}" /></span>
					</td>
					<td width="28%" align="right">
						<fmt:formatDate value="${feedback.createTime}" pattern="yyyy-MM-dd HH:mm:ss" /><fmt:message key="feedback.reply"/>
					</td>
					
				</tr>
				<tr >
					<td colspan="4">
					    <fmt:message key="feedback.subject"/>:<c:out value="${feedback.subject}" escapeXml="true" />
					    <br/>
						<fmt:message key="feedback.content"/>:
						<c:choose>
						<c:when test="${fn:contains(feedback.content,'<body>')}">
							<c:out value="${feedback.content}" escapeXml="true" />
						</c:when>
						<c:otherwise>
						    <c:out value="${feedback.content}" escapeXml="false" />
						</c:otherwise>
						</c:choose>
					</td>
				</tr>   
			  </table>
				<c:forEach var="reply" items="${replyList}">
				 <table width="100%"  border="0" cellspacing="0" cellpadding="0" style="border-bottom:1px dotted #AFAFB0 ">
					<tr>
						<td width="72%" align="left">
						    <span class="color1"><c:out value="${reply.appUser.username}" /></span>
						</td>
						<td width="28%" align="right">
						    <fmt:formatDate value="${reply.createTime}" pattern="yyyy-MM-dd HH:mm:ss" /><fmt:message key="feedback.reply"/>
						</td>
					</tr>
					<tr>
					  <td colspan="4">
					        <fmt:message key="feedback.subject"/>:<c:out value="${reply.subject}" escapeXml="true" />
					        <br/>
					        <fmt:message key="feedback.content"/>:
					        <c:choose>
								<c:when test="${fn:contains(reply.content,'<body>')}">
									<c:out value="${reply.content}" escapeXml="true" />
								</c:when>
								<c:otherwise>
								    <c:out value="${reply.content}" escapeXml="false" />
								</c:otherwise>
							</c:choose>
							<c:if
								test="${feedback.status!=1&&feedback.appUser.appuserId!=reply.appUser.appuserId}">
								<div class="color2" style="float: right">
									<a
										href="#" 
										onclick="cs.feedBack.reply('${feedback.feedbackId}','${reply.feedbackId}')">
										 <fmt:message key="feedback.reply" />
								    </a>
							   </div>
							</c:if>
					  </td>
					</tr>
				  </table>
				</c:forEach>
			   </td>
			   </tr>
			</table>
		</div>
		
	</div>
<div class="fieldset-footer">
			  <input type="image" src="${ctxPath }/images/btn/return.png" onclick="window.history.go(-1);return false;" >
			</div>
</body>

	